package com.dc.project.system.dto;

import com.dc.common.core.PageParamDto;
import com.dc.common.validated.DeleteGroup;
import com.dc.common.validated.InsertGroup;
import com.dc.common.validated.UpdateGroup;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;

/**
 * 系统用户表(SysUser)查询类
 *
 * @author zhuangcy
 * @since 2021-06-01 14:25:29
 */
@Data
@ApiModel(value = "系统用户表Dto")
public class SysUserDto extends PageParamDto {
    /**
     * 用户id
     */
    @NotNull(message = "用户id不能为空", groups = {UpdateGroup.class, DeleteGroup.class})
    @ApiModelProperty(name = "userId", value = "主键")
    private Integer userId;
    /**
     * 用户工号
     */
    @NotNull(message = "用户工号不能为空", groups = {UpdateGroup.class, InsertGroup.class})
    @ApiModelProperty(name = "userCode", value = "用户工号")
    private String userCode;
    /**
     * 用户名称
     */
    @NotNull(message = "用户名称不能为空", groups = {UpdateGroup.class, InsertGroup.class})
    @ApiModelProperty(name = "userName", value = "用户名称")
    private String userName;
    /**
     * 登录账号
     */
    @NotNull(message = "登录账号不能为空", groups = {UpdateGroup.class, InsertGroup.class})
    @ApiModelProperty(name = "account", value = "登录账号")
    private String account;
    /**
     * 登录密码
     */
    @ApiModelProperty(name = "password", value = "登录密码")
    private String password;
    /**
     * 性别
     */
    @ApiModelProperty(name = "gender", value = "性别")
    private String gender;
    /**
     * 手机号码
     */
    @ApiModelProperty(name = "phone", value = "手机号码")
    private String phone;
    /**
     * 邮箱
     */
    @ApiModelProperty(name = "email", value = "邮箱")
    private String email;
    /**
     * 状态（0正常 1停用）
     */
    @ApiModelProperty(name = "status", value = "状态（0正常 1停用）")
    private String status;
    /**
     * 部门id
     */
    @ApiModelProperty(name = "deptId", value = "主键")
    private Integer deptId;
    /**
     * 部门工号
     */
    @ApiModelProperty(name = "deptCode", value = "工号")
    private String deptCode;
    /**
     * 部门名称
     */
    @ApiModelProperty(name = "deptName", value = "名称")
    private String deptName;
    /**
     * 角色id数组
     */
    @ApiModelProperty(name = "roleIds", value = "角色id数组")
    private Integer[] roleIds;
    /**
     * 岗位id数组
     */
    @ApiModelProperty(name = "postIds", value = "岗位id数组")
    private Integer[] postIds;

    @JsonIgnore
    private String[] adminArray;

}